ci: add PR title validation workflow#15
Open
adityamehra wants to merge 1 commit into
Open
Conversation
Enforces Conventional Commits format on all PR titles using amannn/action-semantic-pull-request. Action is pinned to its commit SHA instead of a mutable version tag. Co-authored-by: Cursor <cursoragent@cursor.com>
fercor-cisco
left a comment
Collaborator
There was a problem hiding this comment.
🤖 This review was generated by the Astra agent. It may contain mistakes.
Verdict: approve — Minimal, correctly-configured CI workflow; matches upstream recommended usage with safe permissions and SHA-pinned action.
Follow-ups
Suggested follow-up work that could be tracked as Shortcut stories:
.github/workflows/validate-pr-title.yaml:5-8: Consider addingreopenedto the trigger types. A PR that is closed with an invalid title and later reopened will not re-run the validation until the next edit or push, leaving a stale/missing status. Addingreopenedcloses that gap.
fercor-cisco
left a comment
Collaborator
There was a problem hiding this comment.
This suggestion from the review agent seems to make sense:
Consider adding reopened to the trigger types. A PR that is closed with an invalid title and later reopened will not re-run the validation until the next edit or push, leaving a stale/missing status. Adding reopened closes that gap.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
pull_request_targetso the check also runs on PRs from forksamannn/action-semantic-pull-requestto its commit SHA (0723387faaf9b38adef4775cd42cfd5155ed6017= v5.5.3) instead of a mutable version tagHow it works
The action validates that every PR title matches the Conventional Commits pattern:
Valid types by default:
feat,fix,docs,style,refactor,perf,test,build,ci,chore,revertExamples of passing titles:
feat: add OpenAI instrumentationfix(exporter): handle null span contextchore: update dependenciesThe check re-runs automatically whenever the PR title is edited (
editedevent type), so contributors can fix a failing title without reopening the PR.Permissions
Uses only
pull-requests: read— the action reads the PR title via the GitHub API and sets a commit status. No write access to repository contents is needed.Test plan
Update stuff) and verify the check failspull_request_target)Made with Cursor